package com.example.web;

import com.example.mapper.OracleMapper;
import com.example.pojo.OracleTable;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

/**
 *
 */
@Controller
public class HelloController {

    @ResponseBody
    @RequestMapping("/hello")
    public String hello(){

        return "hello";
    }
    @RequestMapping("/")
    public String index() {

        return "templates/thymeleaf/index";
    }

    @Autowired
    private OracleMapper oracleMapper;


    @ResponseBody
    @RequestMapping("/test")
    void test() {
        System.out.println("");
        List<OracleTable> oracleTables = oracleMapper.listTable("");
        System.out.println(oracleTables);
    }

}
